package com.guigusuqi.survey.service;

import com.guigusuqi.survey.entity.UserQuestionnaire;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author suqi
 * @since 2022-04-13
 */
public interface UserQuestionnaireService extends IService<UserQuestionnaire> {

    /**
     * 通过openid查询用户答题记录
     * @param openid
     * @return
     */
    List<UserQuestionnaire> selectQuestionnaireByOpenid(String openid);

    /**
     * 查询用是否答过该题
     * @param openid
     * @return
     */
    int selectPublishQuestionnaireCount(String openid);
}
